package com.keepsport.keepsportapi.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.keepsport.keepsportapi.entity.User;
import com.keepsport.keepsportapi.entity.UserDetail;
import com.keepsport.keepsportapi.vo.R;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.Date;

public interface UserDetailDao extends BaseMapper<UserDetail> {

    @Update("update t_user set name=#{name} where id=#{token}")
    int updateUserName(User user);
//    @Update("update t_user_detail set city=#{city},introduction=#{introduction},sex=#{sex},hobby=#{hobby},bitthday=#{bitthday},tall=#{tall},weight=#{weight} where id=#{token}")
//    int update(UserDetail userDetail);
//    @Select("select * from t_user_detail where uid=#{token}")
//    UserDetail selectAll(int token);
//
//    @Update("update t_user_detail set city = #{city} where id =#{id}")
//    int updateCity(@Param("id")Integer id,@Param("city") String city);
//
//    @Update("update t_user_detail set sex = #{sex} where id =#{id}")
//    int updateSex(@Param("id")Integer id,@Param("sex") String sex);
//
//    @Update("update t_user_detail set hobby = #{hobby} where id =#{id}")
//    int updateHobby(@Param("id")Integer id,@Param("hobby") String hobby);
//
//    @Update("update t_user_detail set hobby = #{hobby} where id =#{id}")
//    int updateBirthday(@Param("id")Integer id,@Param("birthday") Date birthday);
//
//    @Update("update t_user_detail set tall = #{tall} where id =#{id}")
//    int updateTall(@Param("id")Integer id,@Param("tall") Integer tall);
//
//    @Update("update t_user_detail set weight = #{weight} where id =#{id}")
//    int updateWeight(Integer weight);
}
